import requset from './../utils/request.js'
/**
 * 学生列表
 * @returns 
 */
export function listStu(params) {
    return requset({
        url: '/student/list',
        method: 'GET',
        params,
        isToken: true,
    })
}
/**
 * 专业列表
 * @returns 
 */
export function listMajor() {
    return requset({
        url: '/major/list',
        method: 'GET',
    })
}
/**
 * 添加学生
 * @returns 
 */
export function addStudent(data) {
    return requset({
        url: '/student',
        method: 'POST',
        data,
    })
}
/**
 * 修改学生信息
 * @returns 
 */
export function editStudent(data) {
    return requset({
        url: '/student',
        method: 'PUT',
        data,
    })
}
/**
 * 删除学生信息
 * @returns 
 */
export function delStudent(stuId) {
    return requset({
        url: `/student/${stuId}`,
        method: 'DELETE',
    })
}